#include "startdlg.h"
#include "ui_startdlg.h"

StartDlg::StartDlg(QWidget *parent) :
    QDialog(parent),
    ui(new Ui::StartDlg)
{
    ui->setupUi(this);
    setWindowFlags(Qt::FramelessWindowHint);
    setAttribute(Qt::WA_TranslucentBackground);
//    QPixmap pixmap(":/load.png");
//    setMask(pixmap.mask());
//    QPalette palette;
//    palette.setBrush(QPalette::Background, QBrush( pixmap ) );
//    setPalette(palette);
//    resize( pixmap.size() );
    //setMask(backgroundPixmap_->mask());
}

StartDlg::~StartDlg()
{
    delete ui;
}

void StartDlg::setStatus(const QString &str){
    ui->status_label->setText(str);
    ui->status_label->repaint();
}

void StartDlg::paintEvent(QPaintEvent *){
    QPainter p(this);
    p.drawPixmap(0, 0 , QPixmap(":/pic/load.png"));
}
